package com.jm.common.conf.mybatis;

import org.springframework.stereotype.Service;
import org.springframework.web.context.support.WebApplicationObjectSupport;

import java.util.Objects;

@Service
public class SpringContext extends WebApplicationObjectSupport {
    public <T> T getBean(Class<T> clazz) {
        return Objects.requireNonNull(getApplicationContext()).getBean(clazz);
    }

}
